<?php $this->load->module('mobile/index/header', $common); ?>
    <style>
        .container {
            padding:1%
        }

        .car-left {
            float: left;
            width:100%;
        }
        .carlist li{
            width:46%;
            float:left;
            margin-right:6%;
        }
        .carlist li:nth-child(2n){
            margin-right: 0!important;
        }
        .car-picture{height:114px}
        .search{margin:0 auto!important;}
    </style>
    <div class="container">
        <div class="blank5"></div>
        <div class="jdsearch">
            <form class="search" action="<?php  echo get_url()?>" method="post">
                <input type="text" name="keyword" placeholder="输入车型">
            </form>
        </div>
        <ul class="carlist">
<?php foreach ($list as $key => $val): ?>
    <li class="cl">
                <div class="car">
                    <a href="<?php echo site_url('mobile/rent/profile/?id=' . $val['id']) ?>">
                        <div class="car-left">
                            <div class="car-left1">
                                <img class="car-picture" src="<?php echo URLPIC . $val['thumb'] ?>" onerror="this.error=null;this.src='<?php echo URLPRE; ?>static/public/images/nophoto.jpg'">
                                <h1>[<?php echo $val['brand']; ?>]<?php echo $val['car_type_name']; ?></h1>
 <div class="li-right">
                                <?php if ($val['price_list']): ?>

                                    <?php foreach ($val['price_list'] as $k => $v): ?>

                                        <span><?php echo $v['ws_price']; ?><?php if ($v['price_unit'] == '1'): ?>
                                                <small>元/次</small><?php endif; ?><?php if ($v['price_unit'] == '2'): ?>
                                                <small>元/天</small><?php endif; ?></span>

                                        <br>
                                        <small><?php if ($v['cate_attr'] == '1'): ?>机场接/送<?php endif; ?>
                                            <?php if ($v['cate_attr'] == '2'): ?>短线包车<?php endif; ?>
                                            <?php if ($v['cate_attr'] == '3'): ?>旅游包车<?php endif; ?></small>
                                        <?php
                                        break;
                                    endforeach; ?>
                                    <?php else:?>
                                    <span>电询</span>
                                <?php endif; ?>
     </div>
                            </div>
                        </div>
                    </a>
                </div>
            </li>
<?php endforeach; ?>


        </ul>
    </div>
<?php $this->load->module('mobile/index/footer', $common); ?>